package com.sky.mapper;

import com.sky.entity.SetmealDish;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface SetmealDishMapper {



    Integer selectCount(List<Long> ids);
    /*
     * 新增套餐
     * */
    List<Long> getSetmealIdsByDishIds(List<Long> dishIds);

    /*
     * 新增套餐
     * */
    void insertSetmealDish(List<SetmealDish> setmealDishList);
    /*
     * 根据id查询套餐
     * */
    List<SetmealDish> selectById(Long id);

    @Delete("delete from setmeal_dish where setmeal_id = #{setmealId}")
    void deleteBySetmealId(Long setmealId);

    @Select("select * from setmeal_dish where setmeal_id=#{setmealId}")
    List<SetmealDish> getBySetmealId(Long setmealId);
}
